
<form name="editForm" role="form" novalidate ng-submit="vm.save()" show-validation>

    <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-hidden="true"
                ng-click="vm.clear()">&times;</button>
        <h4 class="modal-title" id="myEnsureIndex2Label" data-translate="byibserverApp.ensureIndex2.home.createOrEditLabel">Create or edit a Ensure Index 2</h4>
    </div>
    <div class="modal-body">
        <jhi-alert-error></jhi-alert-error>
        <div class="form-group" ng-show="vm.ensureIndex2.id">
            <label for="id" data-translate="global.field.id">ID</label>
            <input type="text" class="form-control" id="id" name="id"
                    ng-model="vm.ensureIndex2.id" readonly />
        </div>
        <div class="form-group">
            <label class="control-label" data-translate="byibserverApp.ensureIndex2.index2" for="field_index2">Index 2</label>
            <input type="text" class="form-control" name="index2" id="field_index2"
                    ng-model="vm.ensureIndex2.index2"
                    />
        </div>
        <div class="form-group">
            <label class="control-label" data-translate="byibserverApp.ensureIndex2.index2Info" for="field_index2Info">Index 2 Info</label>
            <input type="text" class="form-control" name="index2Info" id="field_index2Info"
                    ng-model="vm.ensureIndex2.index2Info"
                    />
        </div>
        <div class="form-group">
            <label class="control-label" data-translate="byibserverApp.ensureIndex2.score" for="field_score">Score</label>
            <input type="text" class="form-control" name="score" id="field_score"
                    ng-model="vm.ensureIndex2.score"
                    required/>
            <div ng-show="editForm.score.$invalid">
                <p class="help-block"
                    ng-show="editForm.score.$error.required" data-translate="entity.validation.required">
                    This field is required.
                </p>
            </div>
        </div>
        <div class="form-group">
            <label class="control-label" data-translate="byibserverApp.ensureIndex2.index2Description" for="field_index2Description">Index 2 Description</label>
                <textarea class="form-control" name="index2Description" id="field_index2Description"
                    ng-model="vm.ensureIndex2.index2Description" ></textarea>
        </div>

        <div class="form-group">
            <label data-translate="byibserverApp.ensureIndex2.product" for="field_product">Product</label>
            <select class="form-control" id="field_product" name="product" ng-model="vm.ensureIndex2.productId" ng-options="product.id as product.id for product in vm.products"            >
                <option value=""></option>
            </select>
        </div>
        <div class="form-group">
            <label data-translate="byibserverApp.ensureIndex2.ensureScope" for="field_ensureScope">Ensure Scope</label>
            <select class="form-control" id="field_ensureScope" name="ensureScope" ng-model="vm.ensureIndex2.ensureScopeId" ng-options="ensureScope.id as ensureScope.index1 for ensureScope in vm.ensurescopes"            >
                <option value=""></option>
            </select>
        </div>
    </div>
    <div class="modal-footer">
        <button type="button" class="btn btn-default" data-dismiss="modal" ng-click="vm.clear()">
            <span class="glyphicon glyphicon-ban-circle"></span>&nbsp;<span data-translate="entity.action.cancel">Cancel</span>
        </button>
        <button type="submit" ng-disabled="editForm.$invalid || vm.isSaving" class="btn btn-primary">
            <span class="glyphicon glyphicon-save"></span>&nbsp;<span data-translate="entity.action.save">Save</span>
        </button>
    </div>
</form>
